﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Koonsoft.HYCRM.BLL;

public partial class Deliver_DeliverOrders : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            BindData();
        }
    }

    private void BindData()
    {
        int empolyeeID = new EmpolyeeBLL().GetEmpolyeeInfoByLoginName(User.Identity.Name).EmpolyeeID;
        int selectedmonth = Convert.ToInt32(AuditMonth.SelectedValue);
        int regionID = Convert.ToInt32(DropDownList1.SelectedValue);
        int delegateID = Convert.ToInt32(DropDownList3.SelectedValue);
        int branchID = Convert.ToInt32(DropDownList2.SelectedValue);


        GridView1.DataSource = new OrderBLL().GetDeliverOrders(empolyeeID, selectedmonth,regionID,branchID,delegateID);
        GridView1.DataBind();
    }


    protected void Button1_Click(object sender, EventArgs e)
    {
        BindData();
    }
}